package service.impl;

import dao.StudentDao;
import dao.impl.StudentDaoimpl;
import pojo.Student;
import service.StudentService;

import java.util.Collections;
import java.util.List;

public class StudentServiceimpl implements StudentService {

    StudentDao studentDao = new StudentDaoimpl();
    @Override
    public List<Student> getAllStu() {
        return studentDao.getAllStu();
    }
    public void addStudent(Student student) {
        studentDao.addStudent(student);
    }

    @Override
    public void deleteStudent(String stuNo) {
        studentDao.deleteStudent(stuNo);
    }

    @Override
    public Student getStudentByStuNo(String stuNo) {
        return studentDao.getStudentByStuNo(stuNo);
    }

    @Override
    public void updateStudent(Student student) {
        studentDao.updateStudent(student);
    }
}
